from shotgun_api3 import Shotgun

def connect(SERVER_PATH = 'https://yourshotgunsite.shotgunstudio.com', SCRIPT_NAME = 'test_001', SCRIPT_KEY = 'shotgungeneratedkey'):
	try:
		print "Connecting to %s..." % (SERVER_PATH),
		sg = Shotgun(SERVER_PATH, SCRIPT_NAME, SCRIPT_KEY)
		print "connected"
		return sg
	except Exception, e:
		print "Unable to connect to Shotgun server. "+str(e)
		exit(0)

# Main
if __name__ == '__main__':
	sg = connect()